<%@ Page Title="" Language="C#" MasterPageFile="~/Views/Shared/Site.Master" Inherits="System.Web.Mvc.ViewPage<IEnumerable<VMWorkshop.Domain.ProductListView>>" %>

<asp:Content ID="Content1" ContentPlaceHolderID="TitleContent" runat="server">
	Products List
</asp:Content>

<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">

    <h2>Products</h2>

    <table>
        <tr>
            <th></th>
            <th>Title</th>
            <th>Description</th>
            <th>QuantityOnHand</th>
        </tr>

    <% foreach (var item in Model) { %>
        <tr>
            <td><%= Html.ActionLink("Edit", "Edit", new { id=item.ProductId }) %></td>
            <td><%= Html.Encode(item.Title) %></td>
            <td><%= Html.Encode(item.Description) %></td>
            <td><%= Html.Encode(item.QuantityOnHand) %></td>
        </tr>
    <% } %>

    </table>

</asp:Content>

